<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
String userLoginName = (String)request.getSession().getAttribute("LoginName");
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'reply.jsp' starting page</title>
   <script charset="utf-8" src="kindeditor/kindeditor.js"></script>
	<script charset="utf-8" src="kindeditor/lang/zh_CN.js"></script>
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
  <link rel="stylesheet" href="css/common.css" type="text/css"/>
<script type="text/javascript">
  var editor;
        KindEditor.ready(function(K) {
                editor = K.create('textarea[name="reply"]');
        });
</script>
  </head>
  
  <body>
  
  <div id="allpage"><jsp:include flush="true" page="../index/head.jsp"></jsp:include>
  				    			    <%
			    if(userLoginName==null){
			    	%>
			    	 <div style="text-align:left; width:600px; margin:20px auto;">
			    	<form action="LoginServlet" method="post" >
			    	<label>登录账号&emsp;<input type="text" id="userLoginName" name="userLoginName" style="width:115px; height:20px; line-height:20px; color:#666; border:1px solid #CCC; margin-top:20px;" /></label>
			    	<label>登录密码&emsp;<input type="password" id="passWord" name="passWord" style="width:115px; height:20px; line-height:20px; color:#666; border:1px solid #CCC; margin-top:10px;" /></label>
			    	<br /><label>验&nbsp;证&nbsp;码&emsp;<input type="text" id="inputCheckCode" name="inputCheckCode" value="" style="width:64px; height:20px; line-height:20px; color:#666; border:1px solid #CCC; margin-top:10px;" /></label>
			    	<img alt="请输入四位的验证码" src="pictureCheckCodeServlet" id="pictureCheckCode">
					<a href="javascript:changeImg();" title="更换一张验证码图片">换一张</a>
			    	<input type="submit" value="登录" style="cursor:pointer; width:60px; height:24px; margin-left:30px; background:#aaa; color:#fff; border:2px solid #ccc;">
			    	</form>
			    	<%
			    }
			    %>
    <form id="form1" name="form1" method="post" action="ReplyServlet">
    <input name="id" type="hidden" value="<%=request.getParameter("id") %>"> 
    <input name="rootid" type="hidden" value="<%=request.getParameter("rootid") %>">
    <input type="hidden" name="type" value="2" >
      <br /><br /><textarea name="reply" cols="45" style=" height:300px; width:600px;resize:none; border:1px solid #CCC;" rows="5">
      </textarea>
     <br /><br /><input type="submit" value="提交" style="cursor:pointer; background:#aaa; color:#fff; border:2px solid #ccc; width:60px; height:24px;" />
			    <input type="resit" value="重置" style="cursor:pointer;text-align:center; background:#aaa; color:#fff; border:2px solid #ccc; width:60px; height:24px;" />
			    
    </form>
    </div>

	
	
    
    </div>
  </body>
</html>
